﻿using Feicui.BeautyCRM.Common.Log;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;

namespace Feicui.BeautyCRM.UIPortal.Models.Attribute
{
    /// <summary>
    /// 全局错误过滤器
    /// </summary>
    public class MyExceptionFilterAttribut: HandleErrorAttribute
    {
        public override void OnException(ExceptionContext filterContext)
        {
            //直接将异常写入到日志里
            LogHelper.WriteLog(filterContext.Exception.ToString());

            base.OnException(filterContext);
        }
    }
}